package com.lnsf.bookstore.common.dao;

import com.lnsf.bookstore.system.user.vo.User;

import java.util.List;
import java.util.Map;

public interface BaseDao<T> {

    List<T> queryList(Map<String, Object> map);

    List<T> queryList(Object id);

    int queryTotal(Map<String, Object> map);

    int queryTotal();

    Map queryTotal4Map(Map<String, Object> map);

    T queryObject(Object id);

    int save(T t);

    void save(Map<String, Object> map);

    void saveBatch(List<T> list);

    int update(T t);

    int update(Map<String, Object> map);

    int delete(Object id);

    int delete(Map<String, Object> map);

   //Mapper

    int deleteBatch(Object[] id);

    int deleteByPrimaryKey(Integer id);

    int insert(T record);

    int insertSelective(T record);

    T selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(T record);

    int updateByPrimaryKey(T record);

}
